<!DOCTYPE html>
<html xmlns:th="http://www.w3.org/1999/xhtml">
<meta charset="utf-8">
<style>
	.all{
		height: 40px;
		line-height: 40px;
		border: 1px solid #ccc;
		margin-bottom: 10px;
		text-indent: 1em;
	}

	.model{
		border: 1px solid #ccc;
		box-sizing: border-box;
		margin-bottom: 10px;
		padding: 10px 0;
	}

	.expirationDate{
		display: none;
	}
</style>
<head th:include="include :: header"></head>
<body class="gray-bg">
<div class="wrapper wrapper-content ">
	<div class="row">
		<div class="col-sm-12">
			<div class="ibox float-e-margins">
				<div class="ibox-content">
					<form class="form-horizontal m-t" id="signupForm">

						<input id="id" name="id" th:value="${zykResourcesSecretKey.id}" type="hidden">

						<div class="form-group">
							<label class="col-sm-3 control-label">权限有效期：</label>
							<div class="col-sm-8">
								<select id="period" class="form-control">
									<option value="">请选择</option>
									<option value="1">永久</option>
									<option value="2">时间限定</option>
								</select>
							</div>
						</div>

						<div class="form-group expirationDate">
							<label class="col-sm-3 control-label">截至日期：</label>
							<div class="col-sm-8">
								<input id="entDate" type="hidden" th:value="${zykResourcesSecretKey.entDate} eq null ? '' : ${#dates.format(zykResourcesSecretKey.entDate, 'yyyy-MM-dd HH:mm:ss')}"/>
								<input type="text" class="form-control" id="time" name="entDate" placeholder="选择截至日期">
							</div>
						</div>

						<div class="form-group">
							<label class="col-sm-3 control-label">密钥状态：</label>
							<div class="col-sm-8">
								<input type="hidden" id="states"  th:value="${zykResourcesSecretKey.state}">
								<select id="state" class="form-control">
									<option value="">请选择</option>
									<option value="0">禁用</option>
									<option value="1">启用</option>
								</select>
							</div>
						</div>

						<div class="form-group">
							<label class="col-sm-3 control-label">学校名称：</label>
							<div class="col-sm-8">
								<input type="text" class="form-control" id="schoolName" name="schoolName" placeholder="请输入学校名称" th:value="${zykResourcesSecretKey.schoolName}">
							</div>
						</div>

						<div class="form-group">
							<label class="col-sm-3 control-label">使用人数：</label>
							<div class="col-sm-8">
								<input type="text" class="form-control" id="number" name="number" placeholder="请输入使用人数"  th:value="${zykResourcesSecretKey.number}">
							</div>
						</div>

						<div class="form-group">
							<label class="col-sm-3 control-label">备注：</label>
							<div class="col-sm-8">
								<input type="text" class="form-control" id="remark" name="remark" placeholder="请输入备注" th:value="${zykResourcesSecretKey.remark}">
							</div>
						</div>

						<div class="form-group">
							<label class="col-sm-3 control-label"></label>

							<div class="col-sm-8">

								<div class="all"><span>全部</span> <input type="checkbox"></div>

								<div class="form-group" id="mput">
									<div class="col-sm-12">
										<div th:each="courses : ${coursesAll}" class="col-sm-12 model">
											<p th:text="${courses.key}"></p>
											<label class="checkbox-inline" th:each="resource : ${courses.value}">
												<input  th:text="${resource.name}" class="formValue" type="checkbox" th:value="${resource.id}" th:checked="${resource.isShow}">
											</label>
										</div>
									</div>
								</div>
								<input type="hidden" id="ids">

							</div>
						</div>

						<div class="form-group">
							<div class="col-sm-8 col-sm-offset-3">
								<button type="button" class="btn btn-primary" onclick="update()">提交</button>
							</div>
						</div>
					</form>
				</div>
			</div>
		</div>
	</div>
</div>
<div th:include="include::footer"></div>
<script src="//s.xlongwei.com/res/js/My97DatePicker/WdatePicker.js"></script>
<script type="text/javascript" src="/js/webJs/jzweb/zykResourcesSecretKey/edit.js">
</script>
</body>
</html>
